Repository navigation
ci: keep the Skia cache across unrelated changes and failing later steps - #208
Merged
Merged
Conversation
The Skia cache key hashed every Cargo.toml, all build scripts and the Makefile, so any dependency or script change dropped every entry. Key it on the skia lines and [features] chains of the Cargo.toml files plus the scripts and setup that feed cargo's environment. Each job saved the cache as its last step, so a failing test, AAR or xcframework step lost a Skia build that had succeeded. Save it right after the Rust build.
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Skia cache almost never hits. The 3.0.5 release built Skia from source for every Apple target: Canvas iOS took 121 minutes, about 11 of every 12 per target spent in Skia. There are two causes.
The key was too broad. It hashed every
Cargo.toml, all oftools/scripts/*.shand the Makefile, so any dependency bump or script edit dropped every entry. #206 and #207 each did. The key now covers:Cargo.tomllines that mention skia, and every[features]section, because Skia's features arrive through feature chains such as canvas-ios → canvas-2d/metal → skia-safe/metal. Carriage returns are stripped so Windows checkouts hash the same way..cargo/config.toml, thepre-build.shfiles, the scripts that invoke cargo, and the toolchain setup actions.Computed locally, the key is the same for 3.0.5, #206 and #207, and a change to a Skia feature changes it.
The save was the last step of each job. A failing test, AAR or xcframework step therefore threw away a Skia build that had succeeded, as today's audio test failure did on Linux. Each job now saves right after its Rust build.
Entries are still saved only by master pushes. The canvas iOS, canvas-svg iOS and canvas Android entries will exist once one master run gets past its Rust builds.